/**  
 * All rights Reserved, Designed By www.flksh.com
 * @date:   2017-10-30 11:29:50   
 * @Copyright: 2013-2017 www.flksh.com Inc. All rights reserved. 
 * 注意：本内容仅限于上海福乐康社区养老服务有限公司内部传阅，禁止外泄以及用于其他的商业目
 */
package com.zx.cloud.service;


import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.zx.cloud.domain.Proposal;
import com.zx.cloud.persistence.CrudMapper;
import com.zx.cloud.persistence.ProposalMapper;
import com.zx.cloud.util.Page;

/**
 * 用户意见表
 */
@Service
@Transactional
public class ProposalService extends CrudServiceImpl<Proposal>{
    
    private static final Logger LOGGER = LoggerFactory.getLogger(ProposalService.class);
    
    @Autowired
    private ProposalMapper proposalMapper;
    
  	@Autowired
    public ProposalService(CrudMapper<Proposal> mapper) {
        super(mapper);
    }
    
  	/**
	 * 
	 * @param 得到反馈信息
	 * @param gmc
	 * @param proposal
	 *            反馈实体
	 * @return
	 */
	public Page<Proposal> queryProposalpage(Proposal proposal) {
		long count = proposalMapper.count(proposal);
		Page<Proposal> page = new Page<Proposal>(proposal.getPageIndex_(),proposal.getPageSize_());
		page.setData(proposalMapper.queryProposal(proposal));
		page.setTotalCount(count);
		return page;
	}
	
	
	
}
